gl renderer: Fix text color pre-multiplication
authorTimm Bäder <mail@baedert.org>
Thu, 4 Jan 2018 10:41:51 +0000 (11:41 +0100)
committerTimm Bäder <mail@baedert.org>
Thu, 4 Jan 2018 11:20:27 +0000 (12:20 +0100)
gsk/resources/glsl/coloring.fs.glsl

index 9faab8c45b1c243863800d479b665952d4657f49..7b2e68b4c00bde856f306c357ce300306d287485 100644 (file)
@@ -7,7 +7,7 @@ void main() {
   // pre-multiply
   color.rgb *= color.a;
 
-  color = vec4(u_color.rgb * diffuse.a * u_alpha, diffuse.a * color.a * u_alpha);
+  // u_source is drawn using cairo, so already pre-multiplied.
 
-  setOutputColor(color);
+  setOutputColor(color * diffuse * u_alpha);
 }